#include <stdio.h>
#include <stdlib.h>
typedef int ElemType;
typedef struct BNode {
  ElemType data;
  struct BNode *next;
  struct BNode *prev;
} BNODE;
typedef struct blist {
  struct BNode *head;
  struct BNode *tail;
  int size;
} BLIST;
void InitList(BLIST *list) {
  list->size = 0;
  list->head = (struct BNode*)malloc(sizeof(struct BNode));
  list->head->next = list->head->prev = NULL;
  list->tail = (struct BNode*)malloc(sizeof(struct BNode));
  list->tail->next = list->tail->prev = NULL;
  list->head->next = list->tail;
  list->tail->prev = list->head;
}
void PreInsert(BLIST *list, ElemType elem) {
  //TODO
} void DelAtPos(BLIST *list, int pos) {
  //TODO
}
void PreDel(BLIST *list) {
  DelAtPos(list, 0);
}
void Disp(BLIST *list) {
  BNODE *p = list->head->next;
  while (p != list->tail) {
    printf("%d ", p->data);
    p = p->next;
  }
  printf("\n");
}

int main(void) {
  //TODO
  return EXIT_SUCCESS;
}
